home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 2: Applications / Linux Cubed Series 2 - Applications.iso / circuits / irsim-9.000 / irsim-9 / calibrate / README < prev    next >
Text File  |  1990-12-23  |  10KB  |  249 lines

  1. Irsim prm file
  2. --------------
  3.  
  4.     A prm file consists of a series of lines, each of which begins with a
  5. keyword that determines how the rest of the line is interpreted.  Each line
  6. is of the form:
  7.     <PARAMETER_NAME> <VALUE1> ... <VALUEn>
  8.   A ';' indicates that the rest of the line is to be ignored (a comment).
  9.  
  10. The following parameters are understood by irsim:
  11.  
  12. lambda <real_number>
  13.     Multiplicative constant to convert from .sim file linear dimensions
  14.     (lambdas) to micrometers.
  15.  
  16. capm2a <real_number>
  17.     2nd metal capacitance per unit of area (in f/sq-micron).
  18.  
  19. capm2p <real_number>
  20.     2nd metal capacitance per unit of perimeter (in pf/micron).
  21.  
  22. capma <real_number>
  23.     1st metal capacitance per unit of area (in pf/sq-micron).
  24.  
  25. capmp <real_number>
  26.     1st metal capacitance per unit of perimeter (in pf/micron).
  27.  
  28. cappa <real_number>
  29.     poly capacitance per unit of area (in pf/sq-micron).
  30.  
  31. cappp <real_number>
  32.     poly capacitance per unit of perimeter (in pf/micron).
  33.  
  34. capda <real_number>
  35.     n-diffusion capacitance per unit of area (in pf/sq-micron).
  36.  
  37. capdp <real_number>
  38.     n-diffusion capacitance per unit of perimeter (in pf/micron).
  39.  
  40. cappda <real_number>
  41.     p-diffusion capacitance per unit of area  (in pf/sq-micron).
  42.  
  43. cappdp <real_number>
  44.     p-diffusion capacitance per unit of perimeter (in pf/micron).
  45.  
  46. capga <real_number>
  47.     mosfet gate capacitance per unit of area (in pf/sq-micron).
  48.  
  49. cntpullup <boolean>
  50.     If 0 then the gate capacitance of depletion transistors used as
  51.     pullup devices is NOT included in the output node.  This parameter
  52.     is only significant for nMOS designs which have depletion devices.
  53.     Any number other than 0 will set this flag, this is true for all
  54.     other 'boolean' parameters below.
  55.  
  56. diffperim <boolean>
  57.     If not 0 then the sidewall diffusion capacitance is subtracted
  58.     from the source and drain nodes.  The capacitance is calculated
  59.     as (cpdp * width).  This applies to both n and p transistors.
  60.  
  61. subparea <boolean>
  62.     If not 0 then the poly over transistor capacitance is subtracted
  63.     from the gate node.  The capacitance is calculated as (cappa * area).
  64.  
  65. diffext <real_number>
  66.     Each transistor is assumed to have a rectangular source and drain
  67.     diffusion extending <real_number> units wide and transistor-width
  68.     units high.  The effect of the diffusion extension is to add some
  69.     capacitance to the source and drain nodes of each transistor.
  70.     This is useful when processing the output of NET to improve the
  71.     the capacitive loading approximations without adding explicit load
  72.     capacitors and is not very useful for other types of networks and
  73.     will only be applied if <real_number> is different from 0.
  74.     Diffext is specified in microns (contrary to what some .prm files
  75.     may say).
  76.  
  77. lowthresh <real_number>
  78.     Normalized logic low voltage threshold.  Any voltage <= lowthresh
  79.     is assigned a low logic value (0).
  80.  
  81. highthresh <real_number>
  82.     Normalized logic high voltage threshold.  Any voltage >= highthresh
  83.     is assigned a high logic value (1).  Setting highthresh = lowthresh
  84.     will disallow the unknown(X) node value.  Note that setting highthresh
  85.     lower than lowthresh will not result in nodes having hystereses and
  86.     will probably result in disaster.  Numbers commonly used are for the
  87.     thersholds are 0.4 and 0.6.
  88.  
  89. resistance <type> <context> <width> <length> <resistance>
  90.     Defines the resistance (in ohms) for a transistor of type <type>
  91.     having <width>-<length> dimensions when connected as in <context>.
  92.     Note that the dimensions are in microns (not lambdas).  All of
  93.     <width>, <length>, and <resistance> are real numbers.
  94.  
  95.     Possible types are:
  96.         n-channel
  97.         p-channel
  98.         depletion
  99.         pullup
  100.         resistor
  101.  
  102.     Possible contexts are:
  103.         dynamic-low
  104.         dynamic-high
  105.         static
  106.         power    (parsed but not used)
  107.  
  108.     In addition, the context can be qualified with "-with-drop" but
  109.     irsim does not use this context at all.  It is only parsed for
  110.     backward compatibility with old prm files.
  111.  
  112.     Also for the sake of backward compatibility, the static context is
  113.     not a resistance altogether, but it is used to approximate the
  114.     transistor's transconductance (gm) at the switching point.
  115.  
  116.     For a cmos process, it is sufficient to specify the following:
  117.         n-channel dynamic-low
  118.         n-channel dynamic-high
  119.         n-channel static
  120.  
  121.         p-channel dynamic-low
  122.         p-channel dynamic-high
  123.         p-channel static
  124.  
  125.     You can specify a series of resistance values as irsim will use
  126.     linear interpolation for any non-listed value.  This may be
  127.     particularly important for technologies with channel lengths less
  128.     than ~2um, since short channel effects become important and
  129.     transistor resistance does no longer scale with channel length.
  130.  
  131.  
  132. Notes on .prm files for .sim files created by ext2sim (magic).
  133. --------------------------------------------------------------
  134.  
  135. lambda:
  136.     The first line of a .sim file created by ext2sim contains the following:
  137.     | units: <scale> tech: <tech_name>
  138.     where <tech_name> identifies the technology and <scale> is the 
  139.     multiplicative constant that converts .sim dimensions to centimicrons.
  140.     The correct lambda value for these files should be <scale>/100.0.
  141.     NOTE that irsim ignores this line in the .sim file so it is important
  142.     that it be specified in the .prm file.
  143.  
  144. cap*:
  145.     Magic generates the appropriate layer capacitances when extracting a
  146.     circuit and irsim will not make use of any the following:  capm2a, 
  147.     capm2p, capma, capmp, cappa, cappp, capda, capdp, cappda, cappdp.
  148.     These parameters can be safely set to 0.  Since their value will not
  149.     be used, you can include the appropriate values for documentation.
  150.  
  151. capga:
  152.   Capga should always be specified (unless you want to ignore gate capacitive
  153.   loading - probably a bad idea).  Capga can be calculated directly from the
  154.   process parameters (or corresponding spice deck model) as follows:
  155.  
  156.     capga = Cox / Tox
  157.     where:
  158.         Cox = (Eo)(Eox)
  159.            ~= (8.85)(3.9) pf/m = 34.5 x 10^-6 pf/um
  160.     so that:
  161.         capga = (34.5 x 10^-6) / Tox    (note: Tox in um).
  162.  
  163.     note -    there should really be a capnga & cappga for n and p fets,
  164.         but this is not a severe problem yet.
  165.  
  166. resistance:
  167.     Magic never generates the pullup context and, if a depletion device is
  168.     connected as a pullup, irsim will recognize it as such.  There is no
  169.     need to specify that context.
  170.  
  171. Generating the resistance tables.
  172. ---------------------------------
  173.   If you have a spice model for the transistors in the process, you can use
  174. spice (or some other circuit simulator) to approximate the resistances.  The
  175. following circuit (for a cmos process) can be used to extract the resistances
  176. used by irsim.
  177.  
  178.                  Vdd                    Vdd
  179.                   |                      |
  180.                ___+____               ___+____
  181.           ----o| pmos |          ----o| pmos | 
  182.           |    ---+----   out1   |    ---+----
  183.   in1 ----+       |--------------+       |--------- out2
  184.           |    ___+____    |     |    ___+____   |
  185.           -----| pmos |   ---    -----| nmos |  ---
  186.                ---+----   ---Cap      ---+----  ---Cap
  187.                   |        |             |       |
  188.                  Gnd      Gnd           Gnd     Gnd
  189.  
  190.   Apply a pulse with a rise/fall time of <= .1ns to in1 and measure the
  191. delay from in1 to out1 and from out1 to out2 for both transitions.  Make sure
  192. that Cap is sufficiently large (1pf is ok) otherwise the delay will be
  193. determined primarily by the internal (parasistic) capacitance of the driving
  194. device.  It is a good idea to ratio the 2 inverters so that the midpoint lies
  195. in the middle and you can easily measure the delay.  Make sure the pulse is
  196. sufficiently long to allow the signals to reach a steady state.
  197.  
  198.   From the delays measured, you can extract the resistances as follows:
  199.  
  200.     n-channel dynamic-low = out1.tphl / Cap
  201.     p-channel dynamic-high = out1.tplh / Cap
  202.     n-channel static = (out2.tphl^2 - out1.tphl^2) / (out1.tplh * Cap)
  203.     p-channel static = (out2.tplh^2 - out1.tplh^2) / (out1.tphl * Cap)
  204.  
  205.                 note: a^2 ==> a * a
  206.  
  207.   Similarly, you can masure the delay for an nmos driving a large capacitance
  208. high to determine "n-channel dynamic-high" and a pmos driving a large
  209. capacitance low to determine "p-channel dynamic-low".
  210.  
  211.   Most designs use exclusively minimum length devices, so a single length is
  212. usually sufficient.  Larger than minimum length transistors are typically
  213. only used as charge keepers or in short-circuit protection at the pads, where
  214. the timing is really not relevant.  If the technology does experience short
  215. channel effects (velocity saturation, etc), and you intend to use different
  216. length devices, you should probably generate a copule of table entries.  There
  217. is no need to vary the width of the transistors since the resistance does
  218. scale linearly with the width.
  219.  
  220.   If you have a spice model for your process and access to berkeley spice3xx,
  221. you can use the getres script to automatically generate the resistance
  222. entries.  You will first have to compile findr.c (use "make -f Makefindr").
  223.   Getres takes 2 arguments, a spice model, and a 'device configuration file'
  224. where you specify the sizes of the devices as well as the loading capacitance.
  225.   Getres will setup a spice file, run spice on it, read the rawfile generated
  226. and print the table entries in a file called 'resists' as well as on stdout.
  227.   The 'device configuration' file should look something like this.  This one 
  228. was used to generate the mosis 2um scalable-cmos irsim prm file:
  229.  
  230.     #
  231.     set pwith = 20.0        # with of p-device in um
  232.     set plen = 2.0            # length of p-device in um
  233.     set nwith = 10.0        # with of n-device in um
  234.     set nlen = 2.0            # lenght of n-device in um
  235.     set cap = 1000            # loading capacitance in fF
  236.  
  237.   I have ratioed the p-transistor to be twice as wide to bring the threshold
  238. of the gate closer to 1/2 the swing.  Although this is a crude estimate, it
  239. will work reasonably well for most processes since n-mobility ~ 2 * p-mobility.
  240.  
  241.   You can run getres several times by changing the device sizes in this file.
  242.  
  243.   The following files for the 2um mosis scmos process are included in this
  244. directory as an example:
  245.     mosis2um.spi        spice model card for the process
  246.     dev.2um            'device configuration' file used
  247.     mosis2um.prm        the prm file generated using the above
  248.  
  249.